import requests

cookies = {
    'QN1': '0000f9002f1061b1a1f03eb9',
    'QN48': 'afb67be0-bce1-4d92-83e9-4dc7106b2c02',
    'F234': '1719643710555',
    'QN300': 'organic',
    'AKA_A2': 'A',
    'ctt_june': '1683616182042##iK3waStwaUPwawPwasWhWsvmWsHIaRj%3DaKTRVRD8W%3DX%3DX%3DGDX%3DamX2PmWRfTiK3siK3saKgnVKj%3DasgnaKj%2BVuPwaUvt',
    'Alina': 'b43841b2-cb8e33-3742a330-69a02240-34aa667fae40',
    'QN601': 'f74128ed36864ed443c32e181fad76d7',
    'quinn': '5ec06f07c38934363b49b508c6865a071cf2ea90da1a1bac551129c2b8fed1e29c009a375f00907caca8dae130aba251',
    'QN668': '51%2C57%2C51%2C59%2C56%2C54%2C53%2C57%2C57%2C58%2C53%2C54%2C51',
    'ctf_june': '1683616182042##iK3wVKtsahPwawPwasoRasa%3DWPj%2BXPPnX%3DGTaS2OEPkIVPP%2BWSHDX%3DXNaRaNiK3siK3saKgnVKj%3Dasg%2BVKamVhPwaUvt',
    'QN621': 'fr%3Dtouch_index_search',
    'RT': '"z=1&dm=m.flight.qunar.com&si=e9dd749f-1c9d-403e-ba19-cdf2458c9ae3&ss=lxzrgr1l&sl=1&tt=1fn&rl=1"',
    'cs_june': 'a4e7c8acd60e0c8483c9c4af0f303f8160e5ec80404b2d0abb7d2dab4d034d25b625fe6326e3e1ac3fabf8839818415662f8024fa4617ce275d10d71e312bc1cb17c80df7eee7c02a9c1a6a5b97c1179cd5eef9484e997fba0a4006fc07ef50d5a737ae180251ef5be23400b098dd8ca',
    'F235': '1719643862095',
}

headers = {
    '86389a': '28826966992ff8c337642730716d0c4005c9c35f',
    'accept': 'application/json, text/javascript',
    'accept-language': 'zh-CN,zh;q=0.9,en-US;q=0.8,en;q=0.7',
    'content-type': 'application/json',
    # 'cookie': 'QN1=0000f9002f1061b1a1f03eb9; QN48=afb67be0-bce1-4d92-83e9-4dc7106b2c02; F234=1719643710555; QN300=organic; AKA_A2=A; ctt_june=1683616182042##iK3waStwaUPwawPwasWhWsvmWsHIaRj%3DaKTRVRD8W%3DX%3DX%3DGDX%3DamX2PmWRfTiK3siK3saKgnVKj%3DasgnaKj%2BVuPwaUvt; Alina=b43841b2-cb8e33-3742a330-69a02240-34aa667fae40; QN601=f74128ed36864ed443c32e181fad76d7; quinn=5ec06f07c38934363b49b508c6865a071cf2ea90da1a1bac551129c2b8fed1e29c009a375f00907caca8dae130aba251; QN668=51%2C57%2C51%2C59%2C56%2C54%2C53%2C57%2C57%2C58%2C53%2C54%2C51; ctf_june=1683616182042##iK3wVKtsahPwawPwasoRasa%3DWPj%2BXPPnX%3DGTaS2OEPkIVPP%2BWSHDX%3DXNaRaNiK3siK3saKgnVKj%3Dasg%2BVKamVhPwaUvt; QN621=fr%3Dtouch_index_search; RT="z=1&dm=m.flight.qunar.com&si=e9dd749f-1c9d-403e-ba19-cdf2458c9ae3&ss=lxzrgr1l&sl=1&tt=1fn&rl=1"; cs_june=a4e7c8acd60e0c8483c9c4af0f303f8160e5ec80404b2d0abb7d2dab4d034d25b625fe6326e3e1ac3fabf8839818415662f8024fa4617ce275d10d71e312bc1cb17c80df7eee7c02a9c1a6a5b97c1179cd5eef9484e997fba0a4006fc07ef50d5a737ae180251ef5be23400b098dd8ca; F235=1719643862095',
    'csht': '',
    'origin': 'https://m.flight.qunar.com',
    'pre': '5e032eda-2baf47-63425481-528a5203-513c6450a733',
    'priority': 'u=1, i',
    'referer': 'https://m.flight.qunar.com/ncs/page/flightlist?depCity=%E5%8C%97%E4%BA%AC&arrCity=%E4%B8%8A%E6%B5%B7&goDate=2024-07-08&from=touch_index_search&child=0&baby=0&cabinType=0',
    'sec-fetch-dest': 'empty',
    'sec-fetch-mode': 'cors',
    'sec-fetch-site': 'same-origin',
    'user-agent': 'Mozilla/5.0 (iPhone; CPU iPhone OS 16_6 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/16.6 Mobile/15E148 Safari/604.1',
    'wps': '21',
    'x-requested-with': 'XMLHttpRequest',
}

json_data = {
    'arrCity': '上海',
    'baby': '0',
    'cabinType': '0',
    'child': '0',
    'depCity': '北京',
    'from': 'touch_index_search',
    'goDate': '2024-07-08',
    'firstRequest': True,
    'Bella': '1683616182042##df53d20e9d5838a27e8367aef6efc817fc93ed2c##iKohiK3wgMkMf-i0gUPwaUPsXuPwaUPwaUPwXwPwa5TQjOWxcI10aS30a=D0aS3NWSvwiK3siK3sa2jnVRTGESfDEK3OaKkDWhPwawPwasD+aK2OWRamWSanVKP0aS30a2a0aSisyI0wcIkNiK3wiKWTiK3wjMWHWSf0fID8a9a=WR2AfMD+fR28asWUjMfUVKvwfSj0aS30a2a0aSi=y-ELfuPwaUPsXuPwaUkGWuPmEukhXUkGWuPNawkTXukGWuPmWhkhEUkGWwkhEhPNaukGWUPNXwkhXukGWwkTWukTVhkGWUPNXwPmEhkGWuPmXukTauPwaUPwXwPwaMe0d-oxgMEsiK3wiKWTiK3wiKiRiPPAiKHGiPihiPPNiKtwiPDsiPPAiKt=iPiIiKiRiPPmiKtmiPGTiPP+iKHIiPGDiPPOiK0IiPDAiPPmiPGIiPDwiKiRiK3wiKiRiK3wfIksj+iQgCEQcOm0aS30a=D0aS30EKP0VDP0X230EKP0VKa0XPD0EKP0VRX0X2jpP-kbj-3bjOFeJukGVukTawPNEukGWUPNXwkhXukGWwkTWukTVhPwXwkGWwPmVukhVukGWhkhXUkhWwPwaUPwXwPwaMHxg+X0aS30a=D0aSieqMfLy9opohNno9NHgUNScO=0aS30a2a0aSisj+iQgCEKgMa0aS30a=D0WP30aSi+f9iwf-Wxo-iSfuNSq9W=iK3wiKiRiK3wjOFec9Fbq5GAcMGwd5pbjwPwaUPAEhP+Ehvt##OKGqLYb_dmlaVFKe2AcSO##arrCity,baby,cabinType,child,depCity,from,goDate,firstRequest',
    'startNum': 0,
    'sort': 5,
    'r': 1719643863193,
    '_v': 2,
    'underageOption': '',
    'st': 1719643863192,
    '__m__': '7307c8d5e10dbf45318656630a871899',
}

response = requests.post('https://m.flight.qunar.com/flight/api/touchInnerList', cookies=cookies, headers=headers, json=json_data)

# Note: json_data will not be serialized by requests
# exactly as it was in the original request.
#data = '{"arrCity":"上海","baby":"0","cabinType":"0","child":"0","depCity":"北京","from":"touch_index_search","goDate":"2024-07-08","firstRequest":true,"Bella":"1683616182042##df53d20e9d5838a27e8367aef6efc817fc93ed2c##iKohiK3wgMkMf-i0gUPwaUPsXuPwaUPwaUPwXwPwa5TQjOWxcI10aS30a=D0aS3NWSvwiK3siK3sa2jnVRTGESfDEK3OaKkDWhPwawPwasD+aK2OWRamWSanVKP0aS30a2a0aSisyI0wcIkNiK3wiKWTiK3wjMWHWSf0fID8a9a=WR2AfMD+fR28asWUjMfUVKvwfSj0aS30a2a0aSi=y-ELfuPwaUPsXuPwaUkGWuPmEukhXUkGWuPNawkTXukGWuPmWhkhEUkGWwkhEhPNaukGWUPNXwkhXukGWwkTWukTVhkGWUPNXwPmEhkGWuPmXukTauPwaUPwXwPwaMe0d-oxgMEsiK3wiKWTiK3wiKiRiPPAiKHGiPihiPPNiKtwiPDsiPPAiKt=iPiIiKiRiPPmiKtmiPGTiPP+iKHIiPGDiPPOiK0IiPDAiPPmiPGIiPDwiKiRiK3wiKiRiK3wfIksj+iQgCEQcOm0aS30a=D0aS30EKP0VDP0X230EKP0VKa0XPD0EKP0VRX0X2jpP-kbj-3bjOFeJukGVukTawPNEukGWUPNXwkhXukGWwkTWukTVhPwXwkGWwPmVukhVukGWhkhXUkhWwPwaUPwXwPwaMHxg+X0aS30a=D0aSieqMfLy9opohNno9NHgUNScO=0aS30a2a0aSisj+iQgCEKgMa0aS30a=D0WP30aSi+f9iwf-Wxo-iSfuNSq9W=iK3wiKiRiK3wjOFec9Fbq5GAcMGwd5pbjwPwaUPAEhP+Ehvt##OKGqLYb_dmlaVFKe2AcSO##arrCity,baby,cabinType,child,depCity,from,goDate,firstRequest","startNum":0,"sort":5,"r":1719643863193,"_v":2,"underageOption":"","st":1719643863192,"__m__":"7307c8d5e10dbf45318656630a871899"}'.encode()
#response = requests.post('https://m.flight.qunar.com/flight/api/touchInnerList', cookies=cookies, headers=headers, data=data)
